#pragma once
#include <iostream>
#include <functional>
#include <unistd.h>

void DownloadResource();
void LoadConf();
void SendMessage();

using task_t = std::function<void()>;
task_t tasks[] = { DownloadResource, LoadConf, SendMessage };

void DownloadResource()
{
    std::cout << "downloading resource......\n";
    sleep(1);
}

void LoadConf()
{
    std::cout << "loading conf......\n";
    sleep(1);
}

void SendMessage()
{
    std::cout << "sending message......\n";
    sleep(1);
}
